package com.medaxis.hpams.sso.service.impl;

import com.medaxis.hpams.sso.domain.DictData;
import com.medaxis.hpams.sso.domain.dto.DictDataDto;
import com.medaxis.hpams.sso.mapper.DictDataMapper;
import com.medaxis.hpams.sso.service.DictDataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DictDataServiceImpl implements  DictDataService {
    @Autowired
    DictDataMapper dictDataMapper;
    @Override
    public List<DictDataDto> selectDictDataList(DictDataDto dictDataDto) {
        return dictDataMapper.selectDictDataList(dictDataDto);
    }

    @Override
    public DictDataDto selectDictDataById(Long id) {

        return dictDataMapper.selectDictDataById(id);
    }

    @Override
    public List<DictDataDto> selectDictDataByType(String dictType) {
        return dictDataMapper.selectDictDataByType(dictType);
    }

    @Override
    public int insertDictData(DictDataDto dictDataDto) {
        return dictDataMapper.insertDictData(dictDataDto);
    }

    @Override
    public int updateDictData(DictDataDto dictDataDto) {
        return dictDataMapper.updateDictData(dictDataDto);
    }

    @Override
    public int deleteDictDataByIds(Long[] ids) {
        return dictDataMapper.deleteDictDataByIds(ids);
    }
}
